package apigateway.project.core;

import lombok.Data;

@Data
public class Config {
    //网关端口号
    int port = 8888;

    //连接nacos的ip+端口
    String addressOfNacos = "localhost:8848";

    //用于指定那个配置服务
    String DataId = "test2";

    //用于指定配置中心的Group
    String groupId = "DEFAULT_GROUP";

    //S
    String applicationName = "api-gateway";

    //监听连接请求的线程数
    private int eventLoopGroupBossNum = 1;
    //真正工作的线程数
    private int eventLoopGroupWorkerNum = 1;

    private int maxContentLength = 65536;

    //http Async参数选项:
        //连接超时时间
    private int httpConnectTimeout = 30000;
        //请求超时时间
    private int httpRequestTimeout = 30000;
        //请求重试次数
    private int httpMaxRequestRetry = 2;
        //客户端请求最大连接数
    private int httpMaxConnections = 10000;
        //客户端每个地址支持的最大连接数
    private int httpConnectionPerHost = 8000;
        //客户端空闲连接超时时间
    private int httpPooledConnectionIdleTimeout = 60 * 1000;
}
